package p270jp.pxv.android.viewholder;

import android.view.ViewGroup;
import java.util.ArrayList;
import java.util.List;
import p045be.C1060c;
import p270jp.pxv.android.R;
import p270jp.pxv.android.commonObjects.model.WorkType;
import p314lg.ViewHolderIllustAndMangaAndNovelSegmentBinding;
import p344mj.OnSelectWorkTypeSegmentListener;
import p521th.SolidItemViewHolder;
import p639y6.C7296l;
import p665z6.C7460o;

/* renamed from: jp.pxv.android.viewholder.IllustAndMangaAndNovelWithWorkCountSegmentViewHolder */
/* loaded from: classes2.dex */
public class IllustAndMangaAndNovelWithWorkCountSegmentViewHolder extends SolidItemViewHolder {
    private final ViewHolderIllustAndMangaAndNovelSegmentBinding binding;

    public IllustAndMangaAndNovelWithWorkCountSegmentViewHolder(ViewHolderIllustAndMangaAndNovelSegmentBinding o6Var) {
        super(o6Var.f2666e);
        this.binding = o6Var;
    }

    public static IllustAndMangaAndNovelWithWorkCountSegmentViewHolder createViewHolder(ViewGroup viewGroup, OnSelectWorkTypeSegmentListener aVar, int i, int i2, int i3, WorkType workType) {
        ViewHolderIllustAndMangaAndNovelSegmentBinding o6Var = (ViewHolderIllustAndMangaAndNovelSegmentBinding) C1060c.m10358a(viewGroup, R.layout.view_holder_illust_and_manga_and_novel_segment, viewGroup, false);
        ArrayList arrayList = new ArrayList();
        ArrayList arrayList2 = new ArrayList();
        if (i > 0) {
            arrayList.add(viewGroup.getResources().getString(R.string.illust) + " " + String.valueOf(i));
            arrayList2.add(WorkType.ILLUST);
        }
        if (i2 > 0) {
            arrayList.add(viewGroup.getResources().getString(R.string.manga) + " " + String.valueOf(i2));
            arrayList2.add(WorkType.MANGA);
        }
        if (i3 > 0) {
            arrayList.add(viewGroup.getResources().getString(R.string.novel) + " " + String.valueOf(i3));
            arrayList2.add(WorkType.NOVEL);
        }
        o6Var.f22046q.m4467a((String[]) arrayList.toArray(new String[0]), arrayList2.indexOf(workType));
        o6Var.f22046q.setOnSelectSegmentListener(new C7460o(aVar, arrayList2, 11));
        return new IllustAndMangaAndNovelWithWorkCountSegmentViewHolder(o6Var);
    }

    public static /* synthetic */ void lambda$createViewHolder$0(OnSelectWorkTypeSegmentListener aVar, List list, int i) {
        ((C7296l) aVar).m409b((WorkType) list.get(i));
    }

    @Override // p521th.SolidItemViewHolder
    public void onBindViewHolder(int i) {
    }
}
